package com.atguigu.gulimall.order.service;

import com.alipay.api.AlipayApiException;
import com.atguigu.gulimall.order.vo.PayAsyncVO;
import com.atguigu.gulimall.order.vo.PayVO;

import javax.servlet.http.HttpServletRequest;

/**
 *
 * @ClassName PayService
 * @Description TODO
 * @Author xufb
 * @Date 2024/5/11 17:29:10
 * @Version 1.0
 */
public interface PayService {

    /**
     * 创建支付
     * @param order 订单详情
     */
    public String pay(PayVO order) throws AlipayApiException;

    /**
     * 验签
     * @param request 回参
     */
    Boolean verify(HttpServletRequest request) throws AlipayApiException;

    /**
     * 处理支付异步回调
     * @param asyncVo
     */
    void handlePayResult(PayAsyncVO asyncVo);
}